/**
 * 
 */
package server;

import java.io.*;
import java.util.*;


/**
 * @author Boris
 *
 */
public class Logger implements ILogger {

	private PrintStream LogStream;
	
	/* (non-Javadoc)
	 * @see server.ILogger#AddEntry(java.lang.String, java.lang.String)
	 */
	public void AddEntry(String ModuleName, String Entry) {
		Date date = new Date();
		LogStream.println(date + " : " + ModuleName + " - " + Entry);
	}

	/* (non-Javadoc)
	 * @see server.ILogger#CloseLog()
	 */
	public void CloseLog() {
			LogStream.close();
	}

	/* (non-Javadoc)
	 * @see server.ILogger#OpenLog(java.lang.String)
	 */
	public void OpenLog(String LogFileName) throws FileNotFoundException {
		LogStream = new PrintStream(LogFileName);
	}

}
